/**   
 * @projectName:hxqbFront  
 * @packageName:com.hx.qb.front.news.service.impl  
 * @className:NewsCenterServiceImpl.java  
 *   
 * @createTime:2015年5月19日-下午5:10:43  
 *  
 *    
 */
package com.yn.xr.front.news.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.yn.xr.common.page.Page;
import com.yn.xr.front.news.service.NewsCenterService;
import com.yn.xr.middleware.news.rmi.NewsInfoRmiService;
import com.yn.xr.news.mode.NewsInfo;

/**
 * @description:
 * @fileName:NewsCenterServiceImpl.java
 * @createTime:2015年5月19日 下午5:10:43
 * @author:HX1401125
 * @version 1.0.0
 * 
 */
@Service("newsCenterService")
public class NewsCenterServiceImpl implements NewsCenterService {
	@Resource
	private NewsInfoRmiService newsInfoRmiService;

	@Override
	public Page<NewsInfo> newsCenterPage(String hql, Object[] queryParams,int pageNum, int pageSize) throws Exception {
		Page<NewsInfo> page = null;
		page = newsInfoRmiService.queryNewsInfoPage(hql, queryParams, pageNum, pageSize);
		return page;
	}

	@Override
	public NewsInfo getNewsById( Integer newsId ) throws Exception {
		return newsInfoRmiService.queryNewsInfoById(newsId);
	}

	@Override
	public List<NewsInfo> queryHotNewsInfo(Integer num, Integer platform,
			short type) throws Exception {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public Page<NewsInfo> queryOtherNewsInfoList(int pageNum, int pageSize,
			NewsInfo newsInfo) throws Exception {
		// TODO Auto-generated method stub
		return null;
	}

	/**
	 * @Description: 
	 * @author wangpinwen
	 * @date 2015年8月30日 下午5:11:07 
	 * @version V1.0.0
	 * @param newsInfo
	 * @throws Exception
	 */
	public void saveNewsInfo( NewsInfo newsInfo ) throws Exception {
		newsInfoRmiService.saveNewsInfo(newsInfo);
	}

}
